from django.contrib import admin
from .models import StudentSurvey


@admin.register(StudentSurvey)
class StudentSurveyAdmin(admin.ModelAdmin):
    list_display = ('id', 'gradyear', 'gender', 'age', 'friends', 'created_at')
    list_filter = ('gender', 'gradyear')
    search_fields = ('id', 'gradyear')
    readonly_fields = ('created_at', 'updated_at')
    fieldsets = (
        ('基本信息', {
            'fields': ('gradyear', 'gender', 'age', 'friends')
        }),
        ('运动兴趣', {
            'fields': (
                'basketball', 'football', 'soccer', 'softball',
                'volleyball', 'swimming', 'cheerleading', 'baseball',
                'tennis', 'sports'
            )
        }),
        ('艺术和音乐兴趣', {
            'fields': ('dance', 'band', 'marching', 'music', 'rock')
        }),
        ('宗教相关', {
            'fields': ('god', 'church', 'jesus', 'bible')
        }),
        ('外表和时尚兴趣', {
            'fields': (
                'hair', 'dress', 'blonde', 'mall', 'shopping',
                'clothes', 'hollister', 'abercrombie'
            )
        }),
        ('个性特征评分', {
            'fields': ('cute', 'sexy', 'hot', 'kissed')
        }),
        ('风险行为评分', {
            'fields': ('drunk', 'drugs', 'death', 'die')
        }),
        ('时间信息', {
            'fields': ('created_at', 'updated_at')
        }),
    )
